import request from '/@/utils/request';

export function useMenuApi() {
	return {
		menuList: (params?: object) => {
			return request({
				url: '/api/system/menu/list',
				method: 'post',
				params,
			});
		},

		authMenuList: (params?: object) => {
			return request({
				url: '/api/system/menu/authList',
				method: 'post',
				params,
			});
		},

		editMenu: (data?: object) => {
			return request({
				url: '/api/system/menu/edit',
				method: 'post',
				data,
			});
		},

		deleteMenu: (data?: object) => {
			return request({
				url: '/api/system/menu/delete',
				method: 'post',
				data,
			});
		},
	};
}
